-- defender_ship
-- created by dengc
-- 【描述】技能：守护者飞艇描述

return {
    apply = function(prop, baseValue)
        return prop[3];
    end,

    record = function(target, prop, path)
        return false;
    end,

    desc = function(prop)
        local row = PropM.getRow(prop[1]);
        local desc = row.desc;

        -- 获取boss的位置
        local pos = DungeonBossM.getBossPos();
        if pos == -1 then
            return nil;
        end

        local grid = DungeonM.getGridByPos(pos);
        local monster = grid.monster;
        if not monster or monster:isDead() then
            return nil;
        end

        local curHp = monster:getHp();
        desc = string.gsub(desc, "{prop}", curHp);

        return desc;
    end,
};